<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>人和人律师事务所管理系统v1.0-案件登记</title>

<style type="text/css" media="all">
    .allow-float {clear:none!important;} /* 允许该元素浮动 */
    .stop-float {clear:both!important;} /* 阻止该元素浮动 */
	.float-left {float:left;padding-left:5px}   /*浮动到左边*/
  </style>

	<script type="text/javascript">

		Ext.onReady(function()
		{

		var caseCatalog=[{id:'1',name:'民事案件'},{id:'2',name:'刑事案件'},{id:'3',name:'非诉'},{id:'4',name:'法律顾问'},{id:'5',name:'咨询与代写法律文书'},{id:'6',name:'行政诉讼'},{id:'7',name:'仲裁'}];

		var caseCatalogStore=new Ext.data.JsonStore({data:caseCatalog,fields:["id","name"]});

		var caseProperty=[{id:'1',name:'自主案源'},{id:'2',name:'分配案源'}];

		var casePropertyStore=new Ext.data.JsonStore({data:caseProperty,fields:["id","name"]});

		var settleProperty=[{id:'0',name:'已结案'},{id:'1',name:'未结案'}];

		var settlePropertyStore=new Ext.data.JsonStore({data:settleProperty,fields:["id","name"]});


		var achriveProperty=[{id:'0',name:'已收'},{id:'1',name:'已退'},{id:'2',name:'未收'}];

		var achrivePropertyStore=new Ext.data.JsonStore({data:achriveProperty,fields:["id","name"]});

		var regCaseFormPanel=new Ext.FormPanel(
				{
		collapsible : true,
        labelWidth :110,
        frame : true,
        buttonAlign:'center',
        bodyStyle : 'padding:5px 5px 0',
        waitMsgTarget : true,
        renderTo:'caseReg',
        width:window.screen.width-220,
        height:400,
         defaults : {
            width : 200
        },
        defaultType : 'textfield',
        items : [

        {
        	xtype:'datefield',
        	format:'Y-m-d',
            fieldLabel : '签订时间',
            itemCls:'float-left',//向左浮动
			clearCls:'allow-float',//允许浮动
            name :'rcasesigntime',
             id :'rcasesigntime',
            allowBlank :false
        },


        	new Ext.form.ComboBox({
			fieldLabel:'请选择案件类别',
			itemCls:'float-left',//向左浮动
			clearCls:'allow-float',//允许浮动
			store:caseCatalogStore,
			valueField:'id',
			displayField:'name',
			mode:'local',
			forceSelection:true,
			emptyText:'请选择案件类别',
			hiddenName:'rcasetype',
			editable:false,
			triggerAction:'all',
			id:'rcasetype1',
			name:'rcasetype1'
			}),

			new Ext.form.ComboBox({
			fieldLabel:'请选择案件性质',
			itemCls:'float-left',//向左浮动
			clearCls:'allow-float',//允许浮动
			store:casePropertyStore,
			valueField:'id',
			displayField:'name',
			mode:'local',
			forceSelection:true,
			emptyText:'请选择案件性质',
			hiddenName:'rcaseproperty',
			editable:false,
			triggerAction:'all',
			id:'rcaseproperty1',
			name:'rcaseproperty1'
			}),

         {
            fieldLabel : '合同号',
            itemCls:'float-left',//向左浮动
			clearCls:'allow-float',//允许浮动
            name :'rcontractnumber',
             id :'rcontractnumber',
            allowBlank :false
        },
        {
            fieldLabel : '委托人',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rcaseconsigner',
            id:"rcaseconsigner",
            allowBlank : false
        },
        {
            fieldLabel : '身份证号',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'ridentitynumber',
            id:"ridentitynumber",
            allowBlank : false
        },
         {
            fieldLabel : '联系方式',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rphonenumber',
            id:"rphonenumber",
            allowBlank : false
        },
        {
            fieldLabel : '对方当事人',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'roppositeparty',
            id:"roppositeparty",
            allowBlank : false
        },

        {
            fieldLabel : '事由',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'raffaircause',
            id:"raffaircause",
            allowBlank : false
        },
         {
            fieldLabel : '合同金额',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rcasemoney',
            id:"rcasemoney",
            allowBlank : false
        },
        {
            fieldLabel : '付款情况',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rcasepaystatus',
            id:"rcasepaystatus",
            allowBlank : false
        },
         {
            fieldLabel : '付款备注',
            itemCls:'float-left',//向左浮动
			clearCls:'allow-float',//允许浮动
            name :'rcasepaystatusbrief',
            id:"rcasepaystatusbrief",
            value:'无',
            allowBlank : false
        },

         {
            fieldLabel : '承办律师',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rundertakelawyer',
            id:"rundertakelawyer",
            allowBlank : false
        },
         {
            fieldLabel : '承办备注',
            itemCls:'float-left',//向左浮动
			clearCls:'allow-float',//允许浮动
            name :'rundertakelawyerbrief',
            id:"rundertakelawyerbrief",
            value:'无',
            allowBlank : false
        },
         {
            fieldLabel : '采集人',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rgatherperson',
            id:"rgatherperson",
            value:'无',
            allowBlank : false
        },
        {
            fieldLabel : '采集人提成金额',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rcaser_roy_money',
            id:"rcaser_roy_money",
            value:0,
            allowBlank : false
        },
         {
            fieldLabel : '票据(数字)',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rcasebill',
            id:"rcasebill",
            value:0,
            allowBlank : false
        },

        new Ext.form.ComboBox({
			fieldLabel:'卷宗押金收退情况',
			itemCls:'float-left',//向左浮动
			clearCls:'allow-float',//允许浮动
			store:achrivePropertyStore,
			valueField:'id',
			displayField:'name',
			mode:'local',
			forceSelection:true,
			emptyText:'卷宗押金收退情况',
			hiddenName:'rarchivedeposit',
			editable:false,
			triggerAction:'all',
			id:'archivedeposit1',
			name:'archivedeposit1'
			}),
        {
            fieldLabel : '合同文本(数字)',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rcontracttext',
            id:"rcontracttext",
            allowBlank : false
        },
        {
            fieldLabel : '授权委托书(数字)',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rletterauthor',
            id:"rletterauthor",
            value:0,
            allowBlank : false
        },
        {
            fieldLabel : '法院公函',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rcourtoffletter',
            id:"rcourtoffletter",
            allowBlank : false
        },
        {
            fieldLabel : '检察院公函',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rcheckoffletter',
            id:"rcheckoffletter",
            allowBlank : false
        },
        {
        	xtype:'datefield',
        	format:'Y-m-d',
            fieldLabel : '开庭时间',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rcourtday',
            id:"rcourtday",
            allowBlank : false
        },
        {
            fieldLabel : '介绍信',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rintroletter',
            id:"rintroletter",
            allowBlank : false
        },
        {
            fieldLabel : '律师函',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rlawyersletter',
            id:"rlawyersletter",
            allowBlank : false
        },
        {
            fieldLabel : '会见函',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rinterviewletter',
            id:"rinterviewletter",
            allowBlank : false
        },
        {
            fieldLabel : '其他文本',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rothertext',
            id:"rothertext",
            value:'无',
            allowBlank : false
        },
        new Ext.form.ComboBox({
			fieldLabel:'请选择是否结案',
			itemCls:'float-left',//向左浮动
			clearCls:'allow-float',//允许浮动
			store:settlePropertyStore,
			valueField:'id',
			displayField:'name',
			mode:'local',
			forceSelection:true,
			emptyText:'请选择是否结案',
			hiddenName:'rsettlelawsuit',
			editable:false,
			triggerAction:'all',
			id:'settlelawsuit1',
			name:'settlelawsuit1'
			}),
		 {
            fieldLabel : '备注',
            itemCls:'float-left',//向左浮动
					clearCls:'allow-float',//允许浮动
            name :'rcaseremark',
            id:"rcaseremark",
            allowBlank : false
        }

        ],
         buttons : [ {
            text : '登记',
            disabled : false,
            handler : function() {
                if (regCaseFormPanel.form.isValid()) {
                    regCaseFormPanel.form.submit( {
                        url : 'RegisterCaseInfo.jsj',
                        success : function(from, action) {
                         Ext.MessageBox.alert('结果', action.result.message);
                        },
                        failure : function(form, action) {
                           Ext.MessageBox.alert('结果', action.result.message);
                        },
                        waitMsg : '正在保存数据，稍后...'
                    });
                } else {
                    Ext.Msg.alert('信息', '请填写完成再提交!');
                }
            }
        }
        ]
        });
		});
	</script>
	</head>
	<body>
	<div id="caseReg"></div>
	</body>
</html>

